package com.cssl.repository;

import com.cssl.pojo.Users;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.mongodb.repository.MongoRepository;

public interface UsersRepository extends MongoRepository<Users,Integer> {

    //findBy+字段名+方法后缀
    Users findByUsernameAndPassword(String username,String password);

    Page<Users> findByUsernameLike(String username, Pageable page);
}
